<template>
    <div class="dialog">
        <div class="dialog-con orderItemInfo">
            <div class="order-detail">
                <div class="info">订单导入详情</div>
                <div class="info" @click="confirm" ><i class="iconfont">&#xe64f;</i></div>
            </div>
            <div class="importOrderinfo">
                <p>导入总条数:{{num}}</p>
                <p>导入失败条数:{{failNum}}</p>
            </div>
            <div class="table">
                <el-table
                :data="failOrders"
                border
                @cell-dblclick="celldblclick"
                style="width: 100%">
                <el-table-column
                prop="orderId"
                label="订单号" >
                </el-table-column>
                <el-table-column
                prop="message"
                label="原因">
                </el-table-column>
                </el-table>
            </div>
        </div>
    </div>
</template>
<script>
export default {
    inject:['reload'],
    data(){
        return{
          
        }
    },
    props:{
        num:'',
        failNum:'',
        failOrders:{
            type:Array,
            default:[]
        }
    },
    methods:{
        confirm(){
            this.$emit('closeTip')
            this.reload()
        },
         //实现双击复制
        celldblclick (row, column, cell, event) {
            var _this=this
            this.$copyText(row[column.property]).then(function (e) {
              _this.$message.success("复制成功")
            }, function (e) {
              
            })
        },
    }
    
}
</script>


<style lang="scss" scoped>
.orderItemInfo{
   width:500px;
   height:520px;
   .order-detail{
       display: flex;
       justify-content: space-between;
        .info{
            height:45px;
            line-height:45px;
            text-indent:15px;
            font-weight:700;
            color:#4ee2ef;
            font-size:18px;
            .iconfont{
                font-size:21px;
                margin-right:10px;
            }
        }
   }
   
    .importOrderinfo{
        p{
            height:30px;
            line-height:30px;
            text-indent:15px;
            color:#606266; 
            font-size:15px;
        }
    }
    .table{
        height:330px;
        overflow-y: auto;
    }
}
</style>
